package cloud.daodao.storm.common.file.api;

import cloud.daodao.storm.common.file.constant.FileConstant;
import cloud.daodao.storm.common.file.model.FileData;
import cloud.daodao.storm.common.file.model.FileParam;
import cloud.daodao.storm.common.constant.AppConstant;
import cloud.daodao.storm.common.model.Request;
import cloud.daodao.storm.common.model.Response;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import jakarta.validation.Valid;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.service.annotation.HttpExchange;
import org.springframework.web.service.annotation.PostExchange;

/**
 * @author DaoDao
 */
@Tag(name = "FileApi", description = "文件服务")
@HttpExchange(url = AppConstant.API)
public interface FileApi {

    @Operation(summary = "info 文件信息", description = "@DaoDao 传入文件 id，查询文件信息")
    @PostExchange(url = FileConstant.INFO)
    Response<FileData> info(@RequestBody @Valid Request<FileParam> request);

}
